package top.jiangqiang.qyblog.core.domain.dto;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serial;
import java.io.Serializable;

@Data
@Accessors(chain = true)
@Schema(name = "分类修改", description = "")
public class CategoryUpdateDto implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;
    @Schema(description = "分类ID")
    @NotNull(message = "id不能为空")
    private Long id;

    @Schema(description = "分类名")
    @NotBlank(message = "分类名不能为空")
    private String name;

    @Schema(description = "分类路径别名")
    private String alias;

    @Schema(description = "父级分类id，顶级分类此字段为0")
    private Long parentId;

}
